Jump to content

Database building


Recommended Posts

Guest Colin Hanke
I use phpmyadmin and I currently have a database on my computer for testing and building.  I used the export function and it generated the sql for me to upload my database, table, and its first couple entries.  I copied the sql statement but it gave me an error msg when I tried to query the sql on my hosting for the web.  Here is the query, and the error msg, any help will be greatly appreciated.  Thanks.


MySQL said: Documentation
#1064 - You have an error in your SQL syntax near 'CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
  `Zip` char(10) collate latin1_g' at line 20



- phpMyAdmin SQL Dump
-- version 2.8.1
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: Jun 30, 2006 at 07:19 PM
-- Server version: 5.0.21
-- PHP Version: 5.1.4
--
-- Database: `survey`
--
-- --------------------------------------------------------
--
-- Table structure for table `mktsurvey`
--
CREATE TABLE `mktsurvey` (
`UI` timestamp NOT NULL default CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP ,
`Zip` char( 10 ) COLLATE latin1_general_ci default NULL ,
`age` enum( '18-24', '25-30', '31-35', '36-40', '41-45', '46-50', '51-55', '56-60', '61-65', '+66' ) COLLATE latin1_general_ci default NULL ,
`Children` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`Online_hrs` enum( '0-1', '2-5', '6-10', '11-15', '+15' ) COLLATE latin1_general_ci default NULL ,
`site_cool` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`site_features` varchar( 255 ) COLLATE latin1_general_ci default NULL ,
`buy_child_online` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`times_buy_chile_online` enum( '0-1', '2-5', '6-10', '11-15', '+15' ) COLLATE latin1_general_ci default NULL ,
`myspace` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`online_local_resources` enum( 'Never', 'A Little', 'Often', 'All the Time' ) COLLATE latin1_general_ci default NULL ,
`partic_online_network` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`partic_online_network_why` varchar( 255 ) COLLATE latin1_general_ci default NULL ,
`prize_want` varchar( 255 ) COLLATE latin1_general_ci default NULL ,
`stay_update` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`lm_partic` enum( 'Yes', 'No' ) COLLATE latin1_general_ci default NULL ,
`lmp_artic_why` varchar( 255 ) COLLATE latin1_general_ci default NULL ,
`email` varchar( 255 ) COLLATE latin1_general_ci default NULL ,
`comments` varchar( 255 ) COLLATE latin1_general_ci default NULL ,
`dtstamp` datetime default NULL ,
`gender` char( 6 ) COLLATE latin1_general_ci default NULL ,
PRIMARY KEY ( `UI` )
) ENGINE = MYISAM DEFAULT CHARSET = latin1 COLLATE = latin1_general_ci
Link to comment
https://forums.phpfreaks.com/topic/13351-database-building/
Share on other sites

  • 3 weeks later...
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.