Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting "the requested PHP extension pdo-odbc is missing from your system" on composer update #17

Open
ch0wnag3 opened this issue Aug 24, 2014 · 6 comments

Comments

@ch0wnag3
Copy link

Apologies if this is just user error, but at this point I'm just spinning my wheels. I'm basically getting the same error as the fellow here:

http://stackoverflow.com/questions/22838307/laravel-4-odbc-class-cannot-find-php-extension

I've verified that the extension is loaded on my system by doing a phpinfo() page and php -m. I'm wondering if this could be something as simple a casing issue. My reasoning is that the extension's name show us as PDO_ODBC in both places.

Change this:

    "require": {
        ...
        "ext-pdo_odbc": "*"
    },

To this:

    "require": {
        ...
        "ext-PDO_ODBC": "*"
    },

I'm sure there's a way to test this locally, but until I figure that out, I thought I'd ask here. Thanks in advance for taking the time to read this!

@wstaples
Copy link

Hi ch0wnag3,
What environment are you using? (OS, Laravel Version, 32 or 64 bit ach..)

@ch0wnag3
Copy link
Author

Sorry for the late reply. Here are my environment details:

  • Windows 7 Enterprise SP1 64-bit
  • Laravel 4.2.9
  • PHP 5.5.14 x86

I'm still very new to Laravel development so if I'm omitting something you need please just let me know.

@absentdream
Copy link

i had issues with this and Laravel 4.2 downgrading to 4.1 works. sounds like extension was renamed in different version

@gsisso
Copy link

gsisso commented Sep 30, 2014

this extension is working on laravel 4.2 as well, im using this - https://github.com/wajatimur/odbc-driver

I dont have any issues,it might have 1 issue with the grammer[namespace issue] part but it is very easy to fix.

@JordanDalton
Copy link

gsplash, when you installed the wajatimur/odbc-driver did you run into a "Cannot instantiate abstract class Illuminate\Database\Schema\Grammars\Grammar " error? If so, what did you do to fix it?

@gsisso
Copy link

gsisso commented Nov 6, 2014

Yes I think I had that issue any how thats my odbc connection class -

getGrammarConfig(); ``` if ($grammarConfig) { $packageGrammar = "Illuminate\\Database" . $grammarConfig; if (class_exists($packageGrammar)) { return $this->withTablePrefix(new $packageGrammar); } $illuminateGrammar = "Illuminate\\Database\\Query\\Grammars\\" . $grammarConfig; if (class_exists($illuminateGrammar)) { return $this->withTablePrefix(new $illuminateGrammar); } } return $this->withTablePrefix(new \Illuminate\Database\Query\Grammars\Grammar); } /** * Default grammar for specified Schema * @return Schema\Grammars\Grammar */ protected function getDefaultSchemaGrammar() { $grammarConfig = $this->getGrammarConfig(); if ($grammarConfig) { $packageGrammar = "Illuminate\\Database" . $grammarConfig; if (class_exists($packageGrammar)) { return $this->withTablePrefix(new $packageGrammar); } $illuminateGrammar = "Illuminate\\Database\\Schema\\Grammars\\" . $grammarConfig; if (class_exists($illuminateGrammar)) { return $this->withTablePrefix(new $illuminateGrammar); } } } protected function getGrammarConfig() { if ($this->getConfig('grammar')) { return $this->getConfig('grammar'); } return false; } ``` } I know its not perfect but was really annoyed by that class so I just left it like that when I got no errors

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants