Tag Archives: database

Is it possible to query a database using a value passed in a URL, and write the result of the query to the URL using mod_rewirite?

Questions: Is it possible to use mod_rewrite to write an htaccess rule that takes a url paramater value (for example: id=1, where ‘id’ is the paramater, and ‘1’ is the parameter value), query a database with the parameter value specified, and then write the value returned from the query as a part of the url… Read More »

Speed while searching through a massive Database [closed]

Questions: I’m a database newby. I am wondered about some things in Databases. For example, I saw the structure of how Facebook stores a friend relationship (see : https://developers.facebook.com/docs/reference/fql/friend). There only two columns, 1st users id and the second users id. Well that’s okay. As wikipedia says facebook has around 1 billion active users. So… Read More »

how to get database username and password in hive

Questions: Am writing jdbc program to connect hive database. I want the username and password to give it in the connection url. I don’t know how to get the username and password using hive QL. Can anybody help me out?? Exception in thread “main” java.sql.SQLNonTransientConnectionException: [DataDirect][Hive JDBC Driver]A value was not specified for a required… Read More »

Change database schema during runtime based on logged in user

Questions: I’ve read many questions and answers about dynamic datasource routing and have implemented a solution using AbstractRoutingDataSource and another(see below). That’s fine, but requires hardcoded properties for all datasources. As the number of users using the application increases, this isn’t a suitable way of routing any more. Also it would require to add an… Read More »