Thursday, 3 October 2013

How to get a list of tables is database backup in sql server

How to get a list of tables is database backup in sql server

I have a list of database backup files and I want to see what tables are
in each without loading them. How can I do this quickly ? I am suspicious
that whoever loaded these files into a database perhaps did not do it
properly. No logs available of when the load took place and what it
brought in or in there were errors.

Wednesday, 2 October 2013

Akka - during load testing, forkjoinpool.scan at 20% of cpu time

Akka - during load testing, forkjoinpool.scan at 20% of cpu time

We're making some good progress in load testing and scaling an akka
application but we're seeing scala.concurrent.forkjoin.ForkJoinPool.scan()
coming up as the second highest hotspot around 20% of self time in
visualvm. The Self time (CPU) column says only a fraction of that (say
.05%).
I suspect this means blocking or context switching are potentially
problematic but I'm not too sure - can any one give insight? If it's
context switching I'm guessing tuning dispatcher throughput to a higher
number may net us gains, otherwise if it's caused by blocking we'll need
to read through the code some more.
Any insight greatly appreciated.

COPY string value to byte [] in Java

COPY string value to byte [] in Java

I would like to COPY (not convert) the value of a string to a byte. The
string has been created through transformation of a byte value to base 36,
and then saved as a string.
i.e:
//-------------deconstruct -----------------
byte [] a = [B@7bb4568; // actual byte value
String b = a.toString(); // Copy byte value to a string
String[] parts = b.split("@") ; // split string b to @
String part_1 = parts[0]; // string with value [B
String part_2 = parts[1]; // string with value 7bb4568
//-------------reconstruct -----------------
String c
String pre_fix = "[B@"; // first part of the [B@7bb4568 byte value ,
saved as string
c = pre_fix + parts[1]; // join the two parts
So we have the two parts "reunited" and i want this string value to be
SAVED (and NOT to be converted) as a byte value!
Any ideas???
Thanks in advance!

Tuesday, 1 October 2013

Partialjs - Get model to render in _layout.html

Partialjs - Get model to render in _layout.html

I have a problem when get model in _layout.html
In default.js, I have model like that
exports.install = function(framework) {
framework.route('/', index);
};
function index(){
var model = {menu: {url:'/product',name:'Product'}};
self.view('index', model);
}
in index.html, I can get model.menu
<ul class="menu_index">
<!-- I can see model.menu here -->
<li><a href="{model.menu.url}">{model.menu.name}</a></li>
</ul>
but in _layout.htmt, I can't
<head></head>
<body>
<ul class="menu_layout">
<!-- But I can't see model.menu here -->
<li><a href="{model.menu.url}">{model.menu.name}</a></li>
</ul>
<div>@{body}</div>
</body>
Any suggestion? Thanks

javax.jdo stopped working with App Engine Backend

javax.jdo stopped working with App Engine Backend

I am writing a backend using the google app engine. I have three projects
using this (One of which was a tutorial) and after installing a number of
updates, the
import javax.jdo...
lines started showing error saying that it could not be resolved. I have
tried to google around a bit but haven't had any luck. Is there something
I need to include in the buildpath or some other error? Thanks

Installing Ubuntu on new HDD, replacing it with old HDD running Windows

Installing Ubuntu on new HDD, replacing it with old HDD running Windows

pMy question is related to: a
href=http://askubuntu.com/questions/301032/direct-install-of-ubuntu-into-new-hddDirect
install of Ubuntu into new HDD/a I have a Laptop with Windows 8. I would
like to replace the HDD with a new one and install Ubuntu on it. My
question is if I late replace the Ubuntu-HDD with the Windows-HDD will
Windows 8 run without Problems? Will intalling Ubuntu change BIOS or
something on the pc that can cause any Problems when I insert the old HDD
with Windows?/p pThanks /p

Proof of $X+\csc{\left(\frac{\pi}{X}\right)}>2\csc{\left(\frac{\pi}{2X}\right)}$

Proof of
$X+\csc{\left(\frac{\pi}{X}\right)}>2\csc{\left(\frac{\pi}{2X}\right)}$

When $X$ is greater than 1, I want to prove that
$X+\csc{\left(\frac{\pi}{X}\right)}>2\csc{\left(\frac{\pi}{2X}\right)}$
where $\csc{(\cdot)}=\frac{1}{\sin{(\cdot)}}$.
Plotting the above expression using computer software, the plot shows the
inequality is true.
How to prove it mathematically?
Thanks in advance.