0

I have a query, something like this

$drzava ="CREATE TABLE IF NOT EXISTS`wp_drzava` (
      `ID` int(11) NOT NULL AUTO_INCREMENT,
      `Kod` varchar(2) NOT NULL,
      `Naziv` varchar(100) NOT NULL,
      `NazivSrb` varchar(100) NOT NULL,
      `NazivSrbGenetiv` varchar(100) NOT NULL,
      `jePrevedeno` tinyint(4) DEFAULT '0',
      `jeDrzava` tinyint(1) DEFAULT '1',
      `PhoneCode` varchar(10) DEFAULT NULL,
      `NazivRo` varchar(255) DEFAULT NULL,
      PRIMARY KEY (`ID`)
    ) ENGINE=MyISAM AUTO_INCREMENT=304 DEFAULT CHARSET=utf8;

    INSERT INTO wp_drzava VALUES ('249', 'RO', 'Romania', 'Rumunija', 'Rumunije', null, '1', '+40', 'România ')";

Problem seems to be in România record, so I get not record inserted. I try dbDelta() function and also $wpdb->query() but I get no result.

Any suggestions

1 Answer 1

-2
require_once(ABSPATH . 'wp-admin/includes/upgrade.php');

$drzava = "your sql";

dbDelta($drzava);
1
  • 1
    Please explain why this answer is helpful.
    – kaiser
    Nov 25, 2014 at 16:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.