Razzak / Gary Razzak - thanks for your detailed instructions.
I just copied some of the date info manually from the Set screen in my previous email. The data, as produced by RBase is as follows:- R>show date DATE format dd/mm/yyyy DATE sequence DDMMYYYY Century threshold YEAR is 0 Default CENTURY is 20 I tried an existing table, with the column defined as a date, but the Wizard preview just showed the date as an integer and that is what ended up in the column (which probably was not surprising). I then tried Gary's suggestion of exporting the spreadsheet to a CSV and importing that, which worked - the preview showed a date and one turned up in the correct column. If I get time I may fiddle further with this and see if I can find what I am doing wrong with the XLS file, however I just wanted a quick way to get some data into a table on this occasion. Thank you both for your assistance. Regards, John Docherty -----Original Message----- From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of A. Razzak Memon Sent: Wednesday, 2 March 2005 5:44 p.m. To: RBG7-L Mailing List Subject: [RBG7-L] - Re: Date Conversion - Gateway At 10:43 PM 3/1/2005, John Docherty wrote: >I am importing into a new table, and have the following settings:- > >Date Input DDMMYYYY >Default Century 20 >Century threshold YEAR is 0 If set correctly, a typical SHOW DATE should return the following parameters: DATE format MM/DD/YYYY DATE sequence MMDDYY Century threshold YEAR is 50 Default CENTURY is 19 Your settings may vary. >Can you please clarify your comment re how the column should >be set in RBASE - should it work with the column set to a DATE >type ? (All the other columns, which are just text, appear in >the correct columns, as expected.) Here's how: A. First Approach: Importing as *new* table ------------------------------------------- 01. CONNect dbname 02. Verify/Set DATE settings accordingly 03. Click on File Gateway icon | Import | New Table Enter New Table Name: Select Import Format: MS Excel Spreadsheet (*.xls) Enter File Name: 04. Click on [Start] button Under Import Options for XLS: Select Available Sheet (Sheet1) Check/Verify available fields 05. Available Fields | Highlight Cell [A] Verify/Change the Field Name: Verify Field Type: If TEXT, specify the Field Size Click on [Apply Changes] 06. Repeat Step 05 for all cells and make sure to click on [Apply Changes] for each field, if modified. 07. Verify the First Row and Last Row numbers 08. Click on [OK] button and watch the [Importing ...] process. 09. BROWSE * FROM newtablename ... B. Second Approach: Importing into *existing* table --------------------------------------------------- 01. Know your XLS spreadsheet columns, data types, etc. 02. Define a table (using RBDefine) and assign correct names and data types. 03. Click on File Gateway icon | Import | Existing Table Select Existing Table Name and click on [Start] button 04. Select Excel (*.xls) and click on [Next] button 05. Select Import From File and click on [Next] button 06. Specify First Row and Last Row and click on [Next] button 07. Assign the appropriate cell with the destination column Click on [Next] button 08. Notice the *Preview* (Column Names and appropriate Data) Click on [Next] button 09. Click on Import Mode radio button accordingly Append or Overwrite 10. Click on [Execute] button and watch the [Importing ...] process. 11. BROWSE * FROM existingtablename ... That's all there is to it! Once you understand the process, you may automate the entire import routines using the "Command Line Gateway Import" options. For syntax and detailed examples: 01. HELP GATEWAY 02. Help | Command Line Import/Export ( How To > FileGateway) 03. From The Edge: http://www.razzak.com/fte | GATEWAY 04. R:Docs | Command Line GATEWAY IMPORT . Build Syntax for Command Line GATEWAY IMPORT Very Best R:egards, Razzak. -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.5.5 - Release Date: 1/03/2005
