Kettle Spoon fails find column with Database value lookup - kettle

I'm using Kettle Spoon 7.1.0.0.12 from a while but now I'm experiencing a very weird problem.
I'm using Database Value lookup on a table in my Mysql db. The table field name I'm checking in "account_id" and I'm absolutely sure this column is on the db but I've this error:
2018/03/01 19:55:35 - Database lookup.0 - ERROR (version 7.1.0.0-12, build 1 from 2017-05-16 17.18.02 by buildguy) : Unexpected error
2018/03/01 19:55:35 - Database lookup.0 - ERROR (version 7.1.0.0-12, build 1 from 2017-05-16 17.18.02 by buildguy) : org.pentaho.di.core.exception.KettleStepException:
2018/03/01 19:55:35 - Database lookup.0 - Field [account_id] couldn't be found in the table!
2018/03/01 19:55:35 - Database lookup.0 -
2018/03/01 19:55:35 - Database lookup.0 - at org.pentaho.di.trans.steps.databaselookup.DatabaseLookup.determineFieldsTypesQueryingDb(DatabaseLookup.java:236)
2018/03/01 19:55:35 - Database lookup.0 - at org.pentaho.di.trans.steps.databaselookup.DatabaseLookup.processRow(DatabaseLookup.java:379)
2018/03/01 19:55:35 - Database lookup.0 - at org.pentaho.di.trans.step.RunThread.run(RunThread.java:62)
2018/03/01 19:55:35 - Database lookup.0 - at java.lang.Thread.run(Thread.java:748)
To be absolutely sure I tried to add a input table from the same table and I previewed data and I see the column!
I'm not sure if this is a bug or I'm doing something wrong. I've to add I already use Database Value lookup and it works fine in other cases. Some advice?

Eventually I solved the problem doing a Tool -> Database -> Clear cache.

Related

Issue with Heoku Postgres "could not access file “$libdir/postgis-2.1"

I have a project that works with GeoDjango, Postgis and its deploy it in Heroku.
Some info of what I'm using:
Python 2.7.15
Django 1.11.20
Heroku-18 (Stack)
Postgres 9.4.20
Postgis 2.1.8
In the last months the system threw me an error every time I want to load de geografic info, when I execute a geocode query.
ERROR: could not access file "$libdir/postgis-2.1": No such file or
directory
I have looked for the web and stackoverflow for the solutions and I found some that was really near of my problem but I tried their solutions and doesn't work for me.
I tried the "ALTER EXTENSION postgis UPDATE" solution but throw me this error:
ERROR: cannot create temporary table within security-restricted
operation
I tried the "backup your DB, Drop the local database and restaurations" but when I run the comand pg:backups:capture I get
An error occurred and the backup did not finish.
When I run the pg:backups:info
And trow me this:
2019-03-02 23:08:31 +0000 pg_dump: [archiver (db)] query failed:
ERROR: could not access file "$libdir/postgis-2.1": No such file or
directory ... (some database code) 2019-03-02 23:08:31 +0000
waiting for pg_dump to complete 2019-03-02 23:08:31 +0000 pg_dump
finished with errors
Then I found this entry
Update PostGIS extensions on Heroku
And found that it's the same problem that I have with heroku postgres, (but the author is using ruby) and the author says that was helped by the support team of Heroku. Well I create a ticket and find that "Technical support for Free applications is provided by the online community" and stackoverflow, so I tried to add a comment to this user to say samething like "hey, can you share the solution please? I have the same problem." but I haven't enough reputation to do it.
So what can I do?
I found the solution !!!
With an old db backup archive that I had, I reset the db from the heroku datastores section and after that I restored with the backup archive (with pgAdmin III) and the problem its gonne.
Its seems like the error was with postgis version, becouse when I had the problem my postgis version was 2.1.8 and now with the error solved my versión of postgis is 2.4.4.
I hope it is useful to someone.

Problems with SAS after applying Fix Pack 8 to DB2

We use DB2 (v. 10.5) to store our data. After we had applied Fix Pack 8 to database (client and JDBC driver had been also updated) we faced the following problems:
1) SAS EG didn’t show tables in DB2 libraries;
2) SAS Content Server couldn’t start with the following error in log:
INFO 2017-02-09 14:08:50,541 [server.startup : 1] - Starting repository...
ERROR 2017-02-09 14:08:50,811 [server.startup : 1] - failed to initialize file system
com.ibm.db2.jcc.am.SqlException: DB2 SQL Error: SQLCODE=-443, SQLSTATE=38553, SQLERRMC=SYSIBM.SQLTABLES;TABLES;SYSIBM:CLI:-514, DRIVER=3.67.27
at com.ibm.db2.jcc.am.gd.a(gd.java:752)
As recommended here (http://www-01.ibm.com/support/docview.wss?uid=swg21369762) for similar cases we executed the following commands in DB2:
db2 connect to <databasename>
db2 bind db2schema.bnd blocking all grant public sqlerror continue
db2 terminate
But it has not solved the issues.
What could we forget to do?
How could we try to solve the issue or reveal its root?
Our version of SAS is 9.3. Server OS is AIX, client OS is Windows.

permission denied for relation django_migrations

I am using Django CMS, I want to take backup of my database. But when I am firing the query to take my back of database:
pg_dump -U postgres -h 127.0.0.1 -p 5432 db_name > db_name_backup.sql
After firing the query I am getting the following error:
pg_dump: [archiver (db)] query failed: ERROR: permission denied for relation django_migrations
pg_dump: [archiver (db)] query was: LOCK TABLE public.django_migrations IN ACCESS SHARE MODE
Can anyone help me on this?
Sounds like it's down to permissions, so make sure you at least have USAGE for relevant schema and the SELECT privilege for the table.
Check out this answer for much greater detail.

Flyway Database Migrations on Bluehost Shared Hosting

Folks,
I'm trying to use Flyway on a shared Bluehost server and I'm getting a very cryptic error. Not sure how to troubleshoot.. I'm confident that the basic connection / credentials are working, since changing flyway config settings to a wrong password produces a different error.
Note that I'm able to connect to the database from the command line from the server box using 'mysql -u blah -p' just fine.
Any hints on how to troubleshoot the below? Output from flyway -X init is below.
Flyway config file: http://pastebin.com/8dsWE3W2
Output from ./flyway -X init
/usr/bin/tput
Flyway (Command-line Tool) v.3.0
DEBUG: Adding location to classpath: /home1/philost2/checkout/cocktailbuilder-master/server/_devtools/flyway/bin/../jars/mysql-connector-java-5.1.30-bin.jar
DEBUG: Adding location to classpath: /home1/philost2/checkout/cocktailbuilder-master/server/_devtools/flyway/bin/../jars/h2-1.3.170.jar
ERROR: Unexpected error
org.flywaydb.core.api.FlywayException: Unable to obtain Jdbc connection from DataSource (jdbc:mysql://localhost/philost2_cocktailbuilder_prod?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false) for user '<redacted>'
at org.flywaydb.core.internal.util.jdbc.DriverDataSource.getConnectionFromDriver(DriverDataSource.java:266)
at org.flywaydb.core.internal.util.jdbc.DriverDataSource.getConnection(DriverDataSource.java:226)
at org.flywaydb.core.internal.util.jdbc.JdbcUtils.openConnection(JdbcUtils.java:50)
at org.flywaydb.core.Flyway.execute(Flyway.java:1144)
at org.flywaydb.core.Flyway.init(Flyway.java:970)
at org.flywaydb.commandline.Main.executeOperation(Main.java:118)
at org.flywaydb.commandline.Main.main(Main.java:88)
Caused by: com.mysql.jdbc.exceptions.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??????????????' at line 1
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1049)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4232)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4164)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2615)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2776)
at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2832)
at com.mysql.jdbc.ConnectionImpl.configureClientCharacterSet(ConnectionImpl.java:1937)
at com.mysql.jdbc.ConnectionImpl.initializePropsFromServer(ConnectionImpl.java:3720)
at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2554)
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2321)
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:832)
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:413)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:344)
at org.flywaydb.core.internal.util.jdbc.DriverDataSource.getConnectionFromDriver(DriverDataSource.java:264)

Django-nonrel: Only part of fixture data loading in production

As a learning project, I am using django-nonrel with the GAE to design a site with as much data as possible about the NBA. As such, I need to prepopulate my database (I'm using the GAE-datastore) with most of the data using a fixture, as entering info for 400+ players by hand is simply unthinkable. To that end I've created a .yaml fixture with the following format (taken straight from the django docs example):
- model: players.player
pk: 1
fields:
team: 10
first_name: Jeff
last_name: Adrien
age: 25
pos: SF
gp: 8
- model: players.player
pk: 2
fields:
team: 7
first_name: Arron
last_name: Afflalo
age: 26
pos: SG
gp: 32
Unfortunately, when I run "python manage.py remote loaddata nbadata.yaml', it only loads around the first 190 players (I say around because the first time it loaded 190, the second time it loaded 186) before crapping out and giving me the following error message:
File "/usr/local/google_appengine/lib/fancy_urllib/fancy_urllib/__init__.py",
line 367, in do_open
raise url_error
URLError: <urlopen error [Errno 101] Network is unreachable>
Does anyone know what's going on, and whether there is a solution?
UPDATE: I changed the name of my .yaml file to 'initial_data.yaml' to see if the automatic load would fare better during the syncdb portion of the 'python manage.py deploy' process. I got the following result:
Running syncdb.
Creating tables ...
Installing custom SQL ...
Installing indexes ...
Installed 448 object(s) from 1 fixture(s)
However, when I look in the datastore, there are still only 186 players! Does anyone know what's going on??
The remote API makes an HTTP request to upload each HTTP entity. At some point, your network connection is failing, and the entire operation fails.
Can think of two solutions, but neither is particularly easy:
- Find a better internet connection.
- Patch the fixture upload code in django-nonrel to do some automatic retrying instead of failing.
I'm not certain, but I don't think syncdb really works on production, I believe it just runs against the local datastore, that's why you see that succeeding.