{"action":"created","comment":{"url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/comments/67673603","id":67673603,"diff_hunk":"@@ -973,15 +1115,25 @@ odbcBeginForeignScan(ForeignScanState *node, int eflags)\n     char\t*qual_value = NULL;\n     bool\tpushdown = FALSE;\n \n+    const char* schema_name = svr_schema;\n+\n+    if (!schema_name || !*schema_name)\n+    {\n+      schema_name = svr_database;\n+    }\n+\n #ifdef DEBUG\n     elog(NOTICE, \"odbcBeginForeignScan\");\n #endif\n \n     /* Fetch the foreign table options */\n-    odbcGetOptions(RelationGetRelid(node->ss.ss_currentRelation), &svr_dsn, &svr_database, &svr_schema, &svr_table, &sql_query,\n+    odbcGetOptions(RelationGetRelid(node->ss.ss_currentRelation), &svr_dsn, &svr_driver, &svr_host, &svr_port, &svr_database, &svr_schema, &svr_table, &sql_query,\n                    &sql_count, &username, &password, &col_mapping_list);\n #ifdef DEBUG\n     elog(NOTICE, \"dsn: %s\", svr_dsn);\n+    elog(NOTICE, \"driver: %s\", svr_driver);\n+    elog(NOTICE, \"host: %s\", svr_host);\n+    elog(NOTICE, \"port: %s\", svr_port);","path":"odbc_fdw.c","position":462,"original_position":367,"commit_id":"4fcd54b34cbc15d245ebe88b8392cbb37ee02092","original_commit_id":"76ca2fc8f0937cc9f82e35938daf510d9dd5e174","user":{"login":"rafatower","id":1914276,"avatar_url":"https://avatars.githubusercontent.com/u/1914276?v=3","gravatar_id":"","url":"https://api.github.com/users/rafatower","html_url":"https://github.com/rafatower","followers_url":"https://api.github.com/users/rafatower/followers","following_url":"https://api.github.com/users/rafatower/following{/other_user}","gists_url":"https://api.github.com/users/rafatower/gists{/gist_id}","starred_url":"https://api.github.com/users/rafatower/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafatower/subscriptions","organizations_url":"https://api.github.com/users/rafatower/orgs","repos_url":"https://api.github.com/users/rafatower/repos","events_url":"https://api.github.com/users/rafatower/events{/privacy}","received_events_url":"https://api.github.com/users/rafatower/received_events","type":"User","site_admin":false},"body":"let's change most notices to debug","created_at":"2016-06-20T11:19:46Z","updated_at":"2016-06-20T11:19:46Z","html_url":"https://github.com/CartoDB/odbc_fdw/pull/3#discussion_r67673603","pull_request_url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/comments/67673603"},"html":{"href":"https://github.com/CartoDB/odbc_fdw/pull/3#discussion_r67673603"},"pull_request":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3","id":73597482,"html_url":"https://github.com/CartoDB/odbc_fdw/pull/3","diff_url":"https://github.com/CartoDB/odbc_fdw/pull/3.diff","patch_url":"https://github.com/CartoDB/odbc_fdw/pull/3.patch","issue_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/3","number":3,"state":"open","locked":false,"title":"Fix column values bugs","user":{"login":"jgoizueta","id":5909,"avatar_url":"https://avatars.githubusercontent.com/u/5909?v=3","gravatar_id":"","url":"https://api.github.com/users/jgoizueta","html_url":"https://github.com/jgoizueta","followers_url":"https://api.github.com/users/jgoizueta/followers","following_url":"https://api.github.com/users/jgoizueta/following{/other_user}","gists_url":"https://api.github.com/users/jgoizueta/gists{/gist_id}","starred_url":"https://api.github.com/users/jgoizueta/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jgoizueta/subscriptions","organizations_url":"https://api.github.com/users/jgoizueta/orgs","repos_url":"https://api.github.com/users/jgoizueta/repos","events_url":"https://api.github.com/users/jgoizueta/events{/privacy}","received_events_url":"https://api.github.com/users/jgoizueta/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-06-13T15:42:45Z","updated_at":"2016-06-20T11:19:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fae78fff479af2069687f06e143ecbf0484ce74b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3/commits","review_comments_url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3/comments","review_comment_url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/3/comments","statuses_url":"https://api.github.com/repos/CartoDB/odbc_fdw/statuses/4fcd54b34cbc15d245ebe88b8392cbb37ee02092","head":{"label":"CartoDB:fix-columns","ref":"fix-columns","sha":"4fcd54b34cbc15d245ebe88b8392cbb37ee02092","user":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"repo":{"id":59826841,"name":"odbc_fdw","full_name":"CartoDB/odbc_fdw","owner":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CartoDB/odbc_fdw","description":"PostgreSQL Foreign-data Wrapper for ODBC","fork":true,"url":"https://api.github.com/repos/CartoDB/odbc_fdw","forks_url":"https://api.github.com/repos/CartoDB/odbc_fdw/forks","keys_url":"https://api.github.com/repos/CartoDB/odbc_fdw/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CartoDB/odbc_fdw/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CartoDB/odbc_fdw/teams","hooks_url":"https://api.github.com/repos/CartoDB/odbc_fdw/hooks","issue_events_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/events{/number}","events_url":"https://api.github.com/repos/CartoDB/odbc_fdw/events","assignees_url":"https://api.github.com/repos/CartoDB/odbc_fdw/assignees{/user}","branches_url":"https://api.github.com/repos/CartoDB/odbc_fdw/branches{/branch}","tags_url":"https://api.github.com/repos/CartoDB/odbc_fdw/tags","blobs_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/refs{/sha}","trees_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CartoDB/odbc_fdw/statuses/{sha}","languages_url":"https://api.github.com/repos/CartoDB/odbc_fdw/languages","stargazers_url":"https://api.github.com/repos/CartoDB/odbc_fdw/stargazers","contributors_url":"https://api.github.com/repos/CartoDB/odbc_fdw/contributors","subscribers_url":"https://api.github.com/repos/CartoDB/odbc_fdw/subscribers","subscription_url":"https://api.github.com/repos/CartoDB/odbc_fdw/subscription","commits_url":"https://api.github.com/repos/CartoDB/odbc_fdw/commits{/sha}","git_commits_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/commits{/sha}","comments_url":"https://api.github.com/repos/CartoDB/odbc_fdw/comments{/number}","issue_comment_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/comments{/number}","contents_url":"https://api.github.com/repos/CartoDB/odbc_fdw/contents/{+path}","compare_url":"https://api.github.com/repos/CartoDB/odbc_fdw/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CartoDB/odbc_fdw/merges","archive_url":"https://api.github.com/repos/CartoDB/odbc_fdw/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CartoDB/odbc_fdw/downloads","issues_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues{/number}","pulls_url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls{/number}","milestones_url":"https://api.github.com/repos/CartoDB/odbc_fdw/milestones{/number}","notifications_url":"https://api.github.com/repos/CartoDB/odbc_fdw/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CartoDB/odbc_fdw/labels{/name}","releases_url":"https://api.github.com/repos/CartoDB/odbc_fdw/releases{/id}","deployments_url":"https://api.github.com/repos/CartoDB/odbc_fdw/deployments","created_at":"2016-05-27T10:33:07Z","updated_at":"2016-06-07T10:56:13Z","pushed_at":"2016-06-20T08:31:45Z","git_url":"git://github.com/CartoDB/odbc_fdw.git","ssh_url":"git@github.com:CartoDB/odbc_fdw.git","clone_url":"https://github.com/CartoDB/odbc_fdw.git","svn_url":"https://github.com/CartoDB/odbc_fdw","homepage":"","size":43,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"CartoDB:master","ref":"master","sha":"8b2a00ae4bf505ddb30da2f87a3f48fdf3e42c0d","user":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"repo":{"id":59826841,"name":"odbc_fdw","full_name":"CartoDB/odbc_fdw","owner":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CartoDB/odbc_fdw","description":"PostgreSQL Foreign-data Wrapper for ODBC","fork":true,"url":"https://api.github.com/repos/CartoDB/odbc_fdw","forks_url":"https://api.github.com/repos/CartoDB/odbc_fdw/forks","keys_url":"https://api.github.com/repos/CartoDB/odbc_fdw/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CartoDB/odbc_fdw/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CartoDB/odbc_fdw/teams","hooks_url":"https://api.github.com/repos/CartoDB/odbc_fdw/hooks","issue_events_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/events{/number}","events_url":"https://api.github.com/repos/CartoDB/odbc_fdw/events","assignees_url":"https://api.github.com/repos/CartoDB/odbc_fdw/assignees{/user}","branches_url":"https://api.github.com/repos/CartoDB/odbc_fdw/branches{/branch}","tags_url":"https://api.github.com/repos/CartoDB/odbc_fdw/tags","blobs_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/refs{/sha}","trees_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CartoDB/odbc_fdw/statuses/{sha}","languages_url":"https://api.github.com/repos/CartoDB/odbc_fdw/languages","stargazers_url":"https://api.github.com/repos/CartoDB/odbc_fdw/stargazers","contributors_url":"https://api.github.com/repos/CartoDB/odbc_fdw/contributors","subscribers_url":"https://api.github.com/repos/CartoDB/odbc_fdw/subscribers","subscription_url":"https://api.github.com/repos/CartoDB/odbc_fdw/subscription","commits_url":"https://api.github.com/repos/CartoDB/odbc_fdw/commits{/sha}","git_commits_url":"https://api.github.com/repos/CartoDB/odbc_fdw/git/commits{/sha}","comments_url":"https://api.github.com/repos/CartoDB/odbc_fdw/comments{/number}","issue_comment_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/comments{/number}","contents_url":"https://api.github.com/repos/CartoDB/odbc_fdw/contents/{+path}","compare_url":"https://api.github.com/repos/CartoDB/odbc_fdw/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CartoDB/odbc_fdw/merges","archive_url":"https://api.github.com/repos/CartoDB/odbc_fdw/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CartoDB/odbc_fdw/downloads","issues_url":"https://api.github.com/repos/CartoDB/odbc_fdw/issues{/number}","pulls_url":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls{/number}","milestones_url":"https://api.github.com/repos/CartoDB/odbc_fdw/milestones{/number}","notifications_url":"https://api.github.com/repos/CartoDB/odbc_fdw/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CartoDB/odbc_fdw/labels{/name}","releases_url":"https://api.github.com/repos/CartoDB/odbc_fdw/releases{/id}","deployments_url":"https://api.github.com/repos/CartoDB/odbc_fdw/deployments","created_at":"2016-05-27T10:33:07Z","updated_at":"2016-06-07T10:56:13Z","pushed_at":"2016-06-20T08:31:45Z","git_url":"git://github.com/CartoDB/odbc_fdw.git","ssh_url":"git@github.com:CartoDB/odbc_fdw.git","clone_url":"https://github.com/CartoDB/odbc_fdw.git","svn_url":"https://github.com/CartoDB/odbc_fdw","homepage":"","size":43,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3"},"html":{"href":"https://github.com/CartoDB/odbc_fdw/pull/3"},"issue":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/3"},"comments":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/CartoDB/odbc_fdw/statuses/4fcd54b34cbc15d245ebe88b8392cbb37ee02092"}}}}
{"actor":{"display_login":"rafatower"}}