Unsupported Screen Size: The viewport size is too small for the theme to render properly.

Forum Replies Created

Viewing 15 posts - 2,536 through 2,550 (of 7,398 total)
  • Author
    Posts
  • in reply to: #27541
    peterlaursen
    Participant

    Not sure but I am afraid not. I do not think we can 'squeee' more info from the driver in this situation.

    In our code we could possibly validate for this and popup some message (that will have to be coded in SQLyog) in this situation. Could you suggest such message?

    in reply to: #27539
    peterlaursen
    Participant

    “Per default, SQLyog will produce no rn after each row when exporting fixed width text” .. You enter whatever you want for 'lines terminated by'.

    It will remember next time you open.

    in reply to: #27643
    peterlaursen
    Participant

    If you refer to this: http://dev.mysql.com/doc/refman/5.0/en/ful…#function_match I do not think this is useful here.

    I have no clue how to code this in SQL – I think it would be horrible!.

    And stored procedures/functions in MySQL only support SQL.

    I rather think this should be coded in an application! Basically you need to count the number of occurences of *sequences of SPACE, NEWLINE and TAB*.

    The number if distinct words would then be that number + 1.

    I found this: http://www.ginatrapani.org/workshop/firefo…reawordcounter/

    in reply to: #27535
    peterlaursen
    Participant

    I also wonder if the images you copied into the folder will be a problem? At least a '.dat' filter should be defined.

    in reply to: Export The Connection Settings #24903
    peterlaursen
    Participant

    If that was a question to me I think the answer is the same. Just copy the sqlyog.ini file. Did you try this?

    in reply to: #27645
    peterlaursen
    Participant

    it is not a bug – it is a feature! 😎

    Jokes apart .. I cannot reproduce this! see this

    [attachment=1016:hyph09.jpg]

    I typed as fast as I can. Besides I think such code is not in SQLyog at all. I think it is a keyboard (hardware, driver or interface) issue!

    We will try 2row with different systems, of course. Please tell

    1) Your keyboard layout and language setting

    2) PS2 or USB keyboard?

    3) Wireless keyboard? If so infrared, radio transmitting type, bluetooth?

    4) Any non-microsoft driver involved (like Logitech)?

    Now 'execute' in SQLyog is F9 or F5 depending on your settings! Can you try any other program if '-09' starts the action that F9 or F5 was supposed to do?

    And could you try another keyboard?

    in reply to: #27533
    peterlaursen
    Participant

    I think I should clarify a few points !

    1)

    You are the first user I remember ever asking questions about fixed width CSV files in the 4+ year time we had a Migration Tool in SQLyog. On the opposite we had 200+ questions related to variable width CSV files, I guess. This is no excuse, because as we claim to support both we should also reply better. But in MySQL-context it seems practically nobody uses fixed width files. I think it is a 'speciality' invented by Microsoft!

    2)

    I can import a fixed width file with Migration Tool. Try to repeat like this

    1: export a small table as fixed width CSV with SQLyog

    2: copy that file into an empty folder

    3) With ODBC-manager create a DNS with the text-driver pointing to that folder

    4) Now select the newly created DNS .. click configure .. define format

    5) The 'define format' dialogue opens (the rightmost dialogue in my screensshot). One by one define the type and length of colums and 'add' until every column has been defined.

    6) Now close 3 times .. you will exit the ODBC manager.

    7) Note that you will see that the driver created a schema.ini file in the folder with column definitions as you defined them in the dialogue.

    8) Start migration tool with this DNS

    9) It migrates for me without problems (only some specific datatypes may require additional mapping at the MySQL side as ODBC and MySQL datatypes are not fully compliant. But this you can do from the migration wizard)

    (sorry that my screenshot is Danish, but I cannot help!)

    As I understand your example you have 2 data files and a single schema.ini. Is that valid? Also the definition in your schema.ini does not seem to 'fit' the data file(s) (schema.ini has much more columns as I read it). I still do not understand how your schema.ini was created and if it is supposed to support both of the data files or only one. Maybe you can help with explaining this if you step through the example above?

    in reply to: #27644
    peterlaursen
    Participant

    We use Ctrl+PgUP and Ctrl+PgUp.

    Changelogs for 7.1: “A tab in the Query pane (a Query tab, a Schema Designer tab and a Query Builder tab) can now be closed with Alt+L keyboard shortcut and can now be navigated with Ctrl+pgup and Ctrl+pgdn keyboard shortcuts.” Also check in the Edit – menu!

    in reply to: #27532
    peterlaursen
    Participant

    We have been researching into this but not finished!

    Please see this image:

    [attachment=1015:fixit.jpg]

    In the ODBC manager I define 'source-side' mapping for a (single) fixed-width CSV file created wiht SQLyog CSV export. That results in a schema.ini file being written in the folder where the CSV file is. Now I can migrate succesfully! I suspect that your schema.ini is not valid for the .data files in your example.

    Try navigate with the ODBC manager through the dialogues in the image. Can you 'map' your data files to the schema.ini?

    When reading fixed-width CSV files such 'source-side' mapping needs to be defined. If not there the driver cannot know how to read the file (where one column ends and the next starts). In that respect variable-width CSV files are much simpler to handle (there are escapes that tell this). I think you would avoid a lot of problems using (escaped) variable-width CSV files!

    I also have to say that you are somewhat difficult to understand! *exactly* what can you and what can you not! Will *exactly the example you posted* import into Excel? If then how? Will it create two sheets?

    in reply to: #27640
    peterlaursen
    Participant

    Variables starting with an @ should *not* be declared. They are user/session variables!

    This

    Code:
    BEGIN
    DECLARE Index INT
    DECLARE WordCount INT
    SET Index = 1
    SET WordCount = 0
    ….

    and this

    Code:
    BEGIN
    SET @Index = 1
    SET @WordCount = 0
    …

    .. will both work. The difference is that the variables in the first example will be destroyed when the function ends (the are locally declared variables). The variables in the second example are valid all through the connection/session (they are session/user variables)! But I would *not* use a KEYWORD like 'INDEX' for a variable!

    I suggest you find another resource on the Internet! Why not the MySQL documentation?

    “select + right mouse for copying in message window does not work”

    There is no context menu in messages and objects tabs! But standard Windows shortcut Ctrl+C does copy what is selected!

    in reply to: #27639
    peterlaursen
    Participant

    or three diffent JOIN constructions possible

    1)

    Code:
    SELECT warehouse.unitid FROM warehouse WHERE warehouse.unitid = tbl_name.unitid;

    2)

    Code:
    SELECT warehouse.unitid FROM warehouse INNER JOIN tbl_name ON (warehouse.unitid = tbl_name.unitid);

    3)

    Code:
    SELECT … JOIN … USING …

    (I can never remember that!)

    I would expect JOINs to run faster than SUBSELECTS with large tables .. but depends on indexes too of course!

    in reply to: #27637
    peterlaursen
    Participant

    a comment to the screenshot: simply UNCHECK 'escaped by'. You will not need an escape character at all with this example!

    in reply to: #27636
    peterlaursen
    Participant

    http://dev.mysql.com/doc/refman/5.0/en/load-data.html

    There are two ways with SQLyog: (for both ways the 'tbl_name' must be created in advance. Just create a table with a single integer column)

    1st way

    ********

    execute SQL statement:

    LOAD DATA LOCAL INFILE 'c:\temp\unitid.txt' INTO TABLE tbl_name LINES TERMINATED BY 'rn';

    note

    1) inside a string must be escaped thus 'c:\temp\unitid.txt'

    2) I assume file was created on Windows thus linebreaks 'rn' – if file is created on Linux use 'n' only!

    2nd way:

    *********

    right-click the table you want to import to select 'import from CSV', click the 'change' button and fill in as attached. It will generate exactly same statement as above!

    [attachment=1014:csvsetting.jpg]

    in reply to: #27635
    peterlaursen
    Participant

    You can use shift+click (like in spreadsheet programs, gmail interface etc.).

    Select the checkbox for the first and shift+select the checkbox for the last row and every row will be selected. It was introduced recenttly so you need an updated program version.

    http://webyog.com/faq/content/33/7/en/sqly…on-history.html

    in reply to: #27634
    peterlaursen
    Participant
Viewing 15 posts - 2,536 through 2,550 (of 7,398 total)